<li id="task_<%=task.id%>">
  <%remote_form_for :item,:url=>{:controller=>'work_items',:action=>'mark_task',:id=>"#{task.id}"} do |f|%>
    <%if task.completed==1%>
      <input id="item_completed" type="checkbox" onclick="this.form.onsubmit()" name="item[completed]" checked="checked"/>
      <span class="completed"><%=task.name%></span>
    <%else%>
      <input id="item_completed" type="checkbox" onclick="this.form.onsubmit()" name="item[completed]"/>
      <span class="uncompleted"><%=task.name%></span>
    <%end%>
    <%if task.link%>
      <%=link_to_remote image_tag("blank.png",:title => "查看概要",:class=>"about_item"),:update=>"work_item_#{task.work_item.id}_place",:url=>{:controller=>'whiteboard',:action=>'show_task_info',:user_id=>"#{task.id}"},:complete=>"Element.toggle('work_item_#{task.work_item.id}_place');return false"%>
    <%else%>
      <%= link_to_remote image_tag("blank.png",:title => "删除任务",:class=>"delete_item"), :url=>{:controller=>'work_items',:action=>'destroy_task',:id=>"#{task.id}"}, :confirm => '您确认删除这个任务吗?', :method => :delete %>
    <%end%>
  <%end%>
</li>